package com.oneday.ashop.core.entity.sequence;

import com.oneday.ashop.core.entity.IncIdEntity;
import lombok.Data;
import org.springframework.data.mongodb.core.mapping.Document;

/**
 * 数据库序列实体
 * User:bob.yang
 * Date 2015/7/16 0016
 */
@Document(collection = "Sequence")
@Data
public class Sequence extends IncIdEntity<Integer> {
    /**
     * 表名
     */
    private String className;
    /**
     * 序列号
     */
    private Integer seqNo;

    public Sequence(Integer id, String className, Integer seqNo) {
        setId(id);
        this.className = className;
        this.seqNo = seqNo;
    }
}
